import axios from "axios";
const instance = axios.create({
  baseURL: "http://localhost:3000", //域名
  timeout: 5000, // 超时时间
});

//获取登录状态
export const loginstatusAPI = (params) =>
  instance.get("/login/status", { params: params });
//获取用户信息
export const getusermsgAPI = (params) =>
  instance.get("/user/subcount", { params: params });
//新建歌单
export const createAPI = (data) => instance.post("/playlist/create", data);
//获取用户歌单
export const userlistAPI = (params) =>
  instance.get("/user/playlist", { params: params });
//获取精品歌单
export const goodlistAPI = (params) =>
  instance.get("/top/playlist/highquality", { params: params });
//推荐歌单
export const playlistAPI = (params) =>
  instance.get("/top/playlist", { params: params });
